<!DOCTYPE html>
<html  lang="zh" xmlns:th="http://www.thymeleaf.org">
<head th:replace="include :: header('DEV开发者社区')"></head>
<body>
<div th:replace="include :: top"></div>
<div th:replace="include :: column('index')"></div>

<div class="layui-container">
  <div class="layui-row layui-col-space15">
    <div class="layui-col-md8">
      <div class="fly-panel">
        <div class="fly-panel-title fly-filter">
          <a>置顶</a>
          <a href="#signin" class="layui-hide-sm layui-show-xs-block fly-right" id="LAY_goSignin" style="color: #FF5722;">去签到</a>
        </div>
        <ul class="fly-list">
          <li th:each="article : ${recs}">
            <a th:href="'/user/home/'+${article.bbsUser.userId}" class="fly-avatar">
              <img th:src="${article.bbsUser.avatar}" th:alt="${article.bbsUser.nickname}">
            </a>
            <h2>
              <th:block th:switch="${article.cate}">
              	<a th:case="1" class="layui-badge">提问</a>
              	<a th:case="3" class="layui-badge">讨论</a>
              	<a th:case="4" class="layui-badge">建议</a>
              	<a th:case="99" class="layui-badge">分享</a>
              </th:block>
              <a th:href="'/article/detail/'+${article.id}" th:text="${article.title}"></a>
            </h2>
            <div class="fly-list-info">
              <a th:href="'/user/home/'+${article.bbsUser.userId}" link>
                <cite th:text="${article.bbsUser.nickname}"></cite>
                <i class="iconfont icon-renzheng" th:if="${#strings.length(article.bbsUser.authContent)>0}" th:title="'认证信息：'+${article.bbsUser.authContent}"></i>
<!--                 <i class="layui-badge fly-badge-vip">VIP3</i> -->
              </a>
              <span>[[${#dates.format(article.createTime, 'yyyy-MM-dd HH:mm:ss')}]]</span>
              
              <span class="fly-list-kiss layui-hide-xs" title="悬赏飞吻"><i class="iconfont icon-kiss"></i> [[${article.kiss}]]</span>
              <span class="layui-badge fly-badge-accept layui-hide-xs" th:if="${article.status==9}">已结</span>
              <span class="fly-list-nums"> 
                <i class="iconfont" title="人气">&#xe60b;</i> [[${article.views}]]
                <i class="iconfont icon-pinglun1" title="回答"></i> [[${article.comment}]]
              </span>
            </div>
            <div class="fly-list-badge">
              <span th:if="${article.rec}" class="layui-badge layui-bg-red">精帖</span>
            </div>
          </li>
        </ul>
      </div>

      <div class="fly-panel" style="margin-bottom: 0;">
        
        <div class="fly-panel-title fly-filter">
          <a href="/article/all" class="layui-this">综合</a>
          <span class="fly-mid"></span>
          <a href="/article/all/unsolved">未结</a>
          <span class="fly-mid"></span>
          <a href="/article/all/solved">已结</a>
          <span class="fly-mid"></span>
          <a href="/article/all/rec">精华</a>
     <!--      <span class="fly-filter-right layui-hide-xs">
            <a href="" class="layui-this">按最新</a>
            <span class="fly-mid"></span>
            <a href="">按热议</a>
          </span> -->
        </div>

        <ul class="fly-list">          
          <li th:each="article : ${articles}">
            <a th:href="'/user/home/'+${article.bbsUser.userId}" class="fly-avatar">
              <img th:src="${article.bbsUser.avatar}" th:alt="${article.bbsUser.nickname}">
            </a>
            <h2>
              <th:block th:switch="${article.cate}">
              	<a th:case="1" class="layui-badge">提问</a>
              	<a th:case="3" class="layui-badge">讨论</a>
              	<a th:case="4" class="layui-badge">建议</a>
              	<a th:case="99" class="layui-badge">分享</a>
              </th:block>
              <a th:href="'/article/detail/'+${article.id}" th:text="${article.title}"></a>
            </h2>
            <div class="fly-list-info">
              <a th:href="'/user/home/'+${article.bbsUser.userId}" link>
                <cite th:text="${article.bbsUser.nickname}"></cite>
                <i class="iconfont icon-renzheng" th:if="${#strings.length(article.bbsUser.authContent)>0}" th:title="'认证信息：'+${article.bbsUser.authContent}"></i>
                <!--
                <i class="iconfont icon-renzheng" title="认证信息：XXX"></i>
                <i class="layui-badge fly-badge-vip">VIP3</i>
                -->
              </a>
              <span>[[${#dates.format(article.createTime, 'yyyy-MM-dd HH:mm:ss')}]]</span>
              
              <span class="fly-list-kiss layui-hide-xs" title="悬赏飞吻"><i class="iconfont icon-kiss"></i> [[${article.kiss}]]</span>
              <span class="layui-badge fly-badge-accept layui-hide-xs" th:if="${article.status==9}">已结</span>
              <span class="fly-list-nums"> 
              	<i class="iconfont" title="人气">&#xe60b;</i> [[${article.views}]]
                <i class="iconfont icon-pinglun1" title="回答"></i> [[${article.comment}]]
              </span>
            </div>
            <div class="fly-list-badge">
              <span th:if="${article.rec}" class="layui-badge layui-bg-red">精帖</span>
            </div>
          </li>
         
         
        </ul>
        <div style="text-align: center">
          <div class="laypage-main">
            <a href="/article/all" class="laypage-next">更多帖子</a>
          </div>
        </div>

      </div>
    </div>
    <div class="layui-col-md4">
		<div class="fly-panel">
			<h3 class="fly-panel-title">温馨通道</h3>
			<div class="layui-row fly-panel-main" style="padding: 15px;">
				<div class="layui-clear fly-list-quick">
					<div class="layui-col-xs6">
						<div>
							<a href="https://gitee.com/y_project/RuoYi" target="_blank">Ruoyi</a>
						</div>
					</div>
					<div class="layui-col-xs6">
						<div>
							<a href="https://gitee.com/zhangmrit/RuoYi" target="_blank">RuoYi Oss Mapper </a>
						</div>
					</div>
					<div class="layui-col-xs6">
						<div>
							<a href="https://github.com/zhangmrit/ruoyi-cloud" target="_blank">RuoYi Cloud</a>
						</div>
					</div>
					<div class="layui-col-xs6">
						<div>
							<a href="https://github.com/zhangmrit/ruoyi-ant" target="_blank">RuoYi Ant</a>
						</div>
					</div>
					<div class="layui-col-xs6">
						<div>
							<a href="https://gitee.com/zhangmrit/dev" target="_blank">Dev开发者社区</a>
						</div>
					</div>
					<div class="layui-col-xs6">
						<div>
							<a href="http://club.zmrit.com/cloud-zero/" target="_blank">Spring Cloud 从零开始</a>
						</div>
					</div>
				</div>
			</div>
		</div>


      <div class="fly-panel fly-signin">
        <div class="fly-panel-title">
          签到
          <i class="fly-mid"></i> 
          <a href="javascript:;" class="fly-link" id="LAY_signinHelp">说明</a>
          <i class="fly-mid"></i> 
          <a href="javascript:;" class="fly-link" id="LAY_signinTop">活跃榜<span class="layui-badge-dot"></span></a>
          <span class="fly-signin-days">已连续签到<cite th:text="${sign.days}">0</cite>天</span>
        </div>
        <input type="hidden" id="signRuleList" th:value="${signRuleList}">
        <div class="fly-panel-main fly-signin-main">
          <th:block th:switch="${sign.signed}">
          	<th:block th:case="false">
	          <button class="layui-btn layui-btn-danger" id="LAY_signin">今日签到</button>
	          <span>可获得<cite th:text="${sign.kiss}"></cite>飞吻</span>
          	</th:block>
          	<th:block th:case="true">
	          <button class="layui-btn layui-btn-disabled">今日已签到</button><span>获得了<cite th:text="${sign.kiss}">0</cite>飞吻</span>
          	</th:block>
          </th:block>
        </div>
      </div>

      <div class="fly-panel fly-rank fly-rank-reply" id="LAY_replyRank">
        <h3 class="fly-panel-title">回贴周榜</h3>
        <dl>
        </dl>
      </div>
      <div class="fly-panel fly-list-one" id="LAY_hotRank">
        <h3 class="fly-panel-title">本周热议</h3>
        <dl>
        	<div class="fly-none">没有相关数据</div>
        </dl>
      </div>

      <th:block th:include="include :: adAndFriend"/>

    </div>
  </div>
</div>

<th:block th:include="include :: footer('')"/>


</body>
</html>